package cn.sdhuijin.controller;

import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.ResponseBody;

/**
 * @author sunp@sdhuijin.cn
 * @version 创建时间：2014年12月30日 下午5:29:00 类说明
 */
@Controller
@RequestMapping(value = { "/pos" })
public class POSController {

	@ResponseBody
	@RequestMapping(value = { "/list" })
	public String list(@RequestParam("limit") int limit,
			@RequestParam("start") int start) {
		String result = "{'total':2,'datas':["
				+ "{'id':1001,'frName':'田雨','merchantsName':'滕州市银座广场(荆和店)','merchantsType':'民生类','phoneNum':'13698624361','merchantsAddress':'滕州市荆河西路西首路口','applyType':'银联', 'applyNum':14,'applyDate':'2014-08-03','state':'等待审核'},"
				+ "{'id':1002,'frName':'刘哲','merchantsName':'滕州市小馋熊火锅连锁店','merchantsType':'民生类','phoneNum':'13167091109','merchantsAddress':'滕州市大同北路7号附近','applyType':'银联', 'applyNum':3,'applyDate':'2014-09-09','state':'审核未通过'},"
				+ "{'id':1003,'frName':'邢国栋','merchantsName':'滕州市东郭超市','merchantsType':'民生类','phoneNum':'18790890123','merchantsAddress':'滕州市东郭镇东屯后村附近','applyType':'银联', 'applyNum':2,'applyDate':'2014-11-25','state':'正在办理'},"
				+ "{'id':1004,'frName':'张爱谷','merchantsName':'滕州市7天假日连锁酒店','merchantsType':'民生类','phoneNum':'18236588860','merchantsAddress':'滕州市墨子大道巨人大厦','applyType':'银联', 'applyNum':4,'applyDate':'2014-11-13','state':'未成功办理'},"
				+ "{'id':1005,'frName':'张琳','merchantsName':'滕州市优品汇购物广场','merchantsType':'民生类','phoneNum':'13167091109','merchantsAddress':'滕州市市中区青檀路附近','applyType':'银联', 'applyNum':8,'applyDate':'2014-09-09','state':'成功办理'},"
				+"]}";
		return result;
	}
	
	@ResponseBody
	@RequestMapping(value = { "/searchOne" })
	public String searchOne() {
		String result = "{'data':[{'id':1001,'frName':'张琳','merchantsName':'滕州市优品汇购物广场','merchantsType':'民生类','phoneNum':'13167091109','merchantsAddress':'滕州市市中区青檀路附近','applyType':'银联', 'applyNum':5,'applyDate':'2014-09-09','state':'成功办理'}"
				+ "]}";
		return result;
	}

}
